package com.dcbeida.bean;

import java.io.Serializable;

/**
 * Created by hp on 2016/8/10.
 * 药品监管码详细信息
 */
public class DrugInfo implements Serializable {

    private String drugcode;//监管码

    private int drugid;//药品ID

    private String drugname;//药品名称

    private int quantity;//数量

    private String retailprice;//零售价

    private String salesarea;//销售区域

    private String batchnumber;//药品批次号
    private String expiredate;//有效期

    //额外的参数

    private int stock; //系统库存
    private int count;//数量
    private boolean isFirst;//是否为第一个

    public String getDrugcode() {
        return drugcode;
    }

    public void setDrugcode(String drugcode) {
        this.drugcode = drugcode;
    }

    public int getDrugid() {
        return drugid;
    }

    public void setDrugid(int drugid) {
        this.drugid = drugid;
    }

    public String getDrugname() {
        return drugname;
    }

    public void setDrugname(String drugname) {
        this.drugname = drugname;
    }

    public int getQuantity() {
        return quantity;
    }

    public void setQuantity(int quantity) {
        this.quantity = quantity;
    }

    public String getRetailprice() {
        return retailprice;
    }

    public void setRetailprice(String retailprice) {
        this.retailprice = retailprice;
    }

    public String getSalesarea() {
        return salesarea;
    }

    public String getBatchnumber() {
        return batchnumber;
    }

    public void setBatchnumber(String batchnumber) {
        this.batchnumber = batchnumber;
    }

    public String getExpiredate() {
        return expiredate;
    }

    public void setExpiredate(String expiredate) {
        this.expiredate = expiredate;
    }

    public void setSalesarea(String salesarea) {
        this.salesarea = salesarea;
    }

    public int getStock() {
        return stock;
    }

    public void setStock(int stock) {
        this.stock = stock;
    }

    @Override
    public int hashCode() {
        return super.hashCode();
    }

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count;
    }

    public boolean isFirst() {
        return isFirst;
    }

    public void setFirst(boolean first) {
        isFirst = first;
    }

    @Override
    public boolean equals(Object o) {
        if (o instanceof DrugInfo) {
            if (this.drugcode.equalsIgnoreCase(((DrugInfo) o).drugcode) && this.drugid == ((DrugInfo) o).drugid) {
                return true;
            }
        }
        return false;
    }
}
